package com.qianf.qfoffice.service.impl;

import com.github.pagehelper.PageHelper;
import com.qianf.qfoffice.dao.SkillDao;
import com.qianf.qfoffice.entity.Skill;
import com.qianf.qfoffice.service.SkillService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


@Service
public class SkillServiceImpl implements SkillService {

    @Autowired
    private SkillDao skillDao;


    @Override
    public int addSkill(Skill skill) {
        return skillDao.addSkill(skill);
    }

    @Override
    public List<Skill> findAllSkill(Integer page, Integer limit) {

        PageHelper.startPage(page,limit);

        return skillDao.findAllSkill();
    }
}
